<script>
$(function(){
	$('#start_date').val(INPUT_POST.start_date);
	$('#end_date').val(INPUT_POST.end_date);

	// autocomplete
	$('#username').autocomplete('?app=<?=APP?>&mod=<?=MOD?>',{
		multiple:false,
		width:150,
		multipleSepartator:'',
		dataType:'json',
		minChars:0,
		parse: function(data) {
			var rows = [];
			for (var i=0; i<data.length ;i++ )
			{
				rows[rows.length] = {
					data: data[i].username,
					value: data[i].username,
					result:data[i].username
				};
			}
			return rows;
		},
		formatItem: function(row,i,n) {
			return row;
		},
		formatResult: function(row,i,n) {
			return row;
		},
		formatMatch: function(row,i,max) {
			return row;
		}
	});
});
</script>
<style>
.ac_results {
	padding: 0px;
	border: 1px solid black;
	background-color: white;
	overflow: hidden;
	z-index: 99999;
}

.ac_results ul {
	width: 100%;
	list-style-position: outside;
	list-style: none;
	padding: 0;
	margin: 0;
}

.ac_results li {
	margin: 0px;
	padding: 2px 5px;
	cursor: default;
	display: block;
	/* 
	if width will be 100% horizontal scrollbar will apear 
	when scroll mode will be used
	*/
	/*width: 100%;*/
	font: menu;
	font-size: 12px;
	/* 
	it is very important, if line-height not setted or setted 
	in relative units scroll will be broken in firefox
	*/
	line-height: 16px;
	overflow: hidden;
}

.ac_loading {
	background: white url('indicator.gif') right center no-repeat;
}

.ac_odd {
	background-color: #eee;
}

.ac_over {
	background-color: #0A246A;
	color: white;
}
</style>
<div class="line_1"></div>
<form id="post" method="post" enctype="application/x-www-form-urlencoded">

<div class="list-div" style="margin-bottom:5px;">
    <table>
        <tr>
            <td align="center">
				开始时间：<input type="text" id="start_date" name="start_date" readonly="1" onclick="new Calendar(2011,2018).show(this)"  />
				结束时间：<input type="text" id="end_date" name="end_date" readonly="1" onclick="new Calendar(2011,2018).show(this)"  />
				&nbsp;&nbsp;&nbsp;
				按<select style="width:auto" name="stp">
				<option>天</option>
				<option>月</option>
				</select>显示
				&nbsp;&nbsp;&nbsp;
				<input type="text" name="q" id="username" value="<?=$this->search_user?>" />
				<input type="submit" value="搜索"/>
			</td>
        </tr>
    </table>
</div>

</form>

<?php if(POST): ?>
<div class="list-div" style="margin-bottom:5px;">
    <table>
        <tr>
            <td align="center">
				<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" id="graph-2" align="middle" width="100%" height="400px">
					<param name="allowScriptAccess" value="sameDomain" />
					<param name="movie" value="./res/image/ofc.swf?width=100px&height=100px&data-file=<?=$this->data_url?>&r=<?=microtime()?>" />
					<param name="quality" value="high" />
					<param name="bgcolor" value="#FFFFFF" />
					<embed src="./res/image/ofc.swf?width=600px&height=100px&data-file=<?=$this->data_url?>&r=<?=microtime()?>" quality="high" bgcolor="#FFFFFF" width="100%" height="400px;"name="open-flash-chart" align="middle" allowScriptAccess="sameDomain" type="application/x-shockwave-flash" pluginspage="http://www.macromedia.com/go/getflashplayer" />
				</object>
			</td>
        </tr>
    </table>
</div>
<?php endif; ?>